﻿<Window x:Class="BookvarWpf.Windows.RecoveredMaps"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:r="clr-namespace:Bookvar.UI.Localization;assembly=Bookvar.UI"
        xmlns:local="clr-namespace:BookvarWpf.Windows"
        Width="550"     
        Height="400"
        Title="{r:Resources RecoveredMapsTitleText}"
        Background="{StaticResource ListBackground}"
        ResizeMode="NoResize" WindowStartupLocation="CenterScreen" WindowStyle="SingleBorderWindow"
        x:Name="window"
    >
    <Window.Resources>
    </Window.Resources>
    <Grid  Margin="10,10,10,10">
        <Grid.RowDefinitions>
            <RowDefinition Height="30" />
            <RowDefinition Height="*" />            
            <RowDefinition Height="35" />            
        </Grid.RowDefinitions>
        <TextBlock Grid.Row="0" Text="{r:Resources RecoveredMapsDescriptionText}" VerticalAlignment="Center" />
        <ListView Grid.Row="1" BorderThickness="0" Name="lvRecoveredMaps" ScrollViewer.HorizontalScrollBarVisibility="Disabled"
            ScrollViewer.VerticalScrollBarVisibility="Auto" VirtualizingStackPanel.IsVirtualizing="True" ScrollViewer.CanContentScroll="True">           
            <ListView.View>
                <GridView>
                    <GridViewColumn Header="{r:Resources TitleDefaultText}" 
                        DisplayMemberBinding="{Binding Name}" 
                        Width="300" />
                    <GridViewColumn Header="{r:Resources ActionDefaultText}" Width="230">
                        <GridViewColumn.CellTemplate>
                            <DataTemplate>
                                    <ComboBox Width="190"
                                        SelectedValue="{Binding Action}" ItemsSource="{Binding RecoverActions, ElementName=window}" 
                                        DisplayMemberPath="Value" SelectedValuePath="Key" />
                            </DataTemplate>
                        </GridViewColumn.CellTemplate>
                    </GridViewColumn>
                </GridView>
            </ListView.View>
        </ListView>
        <Button Click="OnOkClick"  Grid.Row="2" Margin="5" Content="{r:Resources OkDefaultText}" HorizontalAlignment="Right"></Button>
    </Grid>

</Window>
